#ifndef GRAPH_H
#define GRAPH_H

#include <GLObject.h>

#include <Node.h>
#include <Edge.h>

#include <vector>

class Graph : public GLObject
{
public:
    Graph( void ) { }
    virtual ~Graph( void ) {
        while( !m_edges.empty() ) {
            Edge* edge = m_edges.back();
            m_edges.pop_back();
            delete edge;
        }
        while( !m_nodes.empty() ) {
            Node* node = m_nodes.back();
            m_nodes.pop_back();
            delete node;
        }
    }

    void Insert( Node *node ) {
        m_nodes.push_back( node );
    }

    void Insert( Edge *edge ) {
        m_edges.push_back( edge );
    }

    void draw( void ) {

    }

private:
    std::vector<Node*> m_nodes;
    std::vector<Edge*> m_edges;
};

#endif // GRAPH_H
